<?php 

class CategoriesWidget extends CWidget {

    public function run() {
			$criteria=new CDbCriteria;
			$criteria->select= array('name', 'alias');
      $models = NewsCategories::model()->findAll($criteria);

			$this->render('categories', array(
					'models'=>$models   
			));
    }
}
